package logic.bean;

import com.shwread.android.ui.widget.slideview.SlideView;

import java.io.Serializable;
import java.util.List;


public class MessageInfo
        implements
        Serializable
{
	private static final long   serialVersionUID    = 1L;
	public static final int     TYPE_BOOK           = 1; //书籍外链
	public static final int     TYPE_URL            = 2; //URL外链
	public static final int     TYPE_BANNER         = 3; //专题
	public static final int     TYPE_SYSTEM         = 4; //系统通知
	public static final int     TYPE_LIVES          = 5; //活动
	public static final int     TYPE_ORDER          = 8; //预约订座
	public static final int     TYPE_COUPON         = 9; //赠送代金券
	public static final int     TYPE_RENBAO         = 10;
	public static final int     TYPE_QIANDAO         = 13;// 签到提醒
	public static final int     TYPE_QINGJIA        = 14;// 请假提醒
	public static final int     TYPE_CHUCAI        = 15;// 出差提醒
	public static final int     TYPE_JIABAN        = 16;// 加班提醒
	public static final int     FIRM_MESSAGE_TYPE   = 1;
	public static final int     SYSTEM_MESSAGE_TYPE = 2;
	
	private String              title;
	private String              shortMsg;
	private String              lastMsgTime;
	private List<BookInfo>      books;
	private String              position;
	private String              createTime;
	private long                bookId;
	private String              endTime;
	private int                 sortNum;
	private String              startTime;
	private String              author;
	private int                 level;
	private String              endTime2;
	private int                 msgId;
	private String              modifyTime;
	private int                 msgViewId;
	private int                 thirdEnterpriseId;
	private String              status;
	private int                 handerId;
	private String              addressUrl;
	private String              msgImgUrl;
	private String              writeSource;
	private String              msgContent;
	private String              account;
	private int                 msgType;
	private String              startTime2;
	private String              isRead;
	private long                sendStartTime;
	private transient SlideView slideView;
	
	public long getSendStartTime() {
		return sendStartTime;
	}
	
	public void setSendStartTime(long sendStartTime) {
		this.sendStartTime = sendStartTime;
	}
	
	@Override
	public String toString() {
		return "MessageInfo [sendStartTime=" + sendStartTime + ", msgId=" + msgId + ", msgViewId=" + msgViewId + ",title=" + title + ", msgContent=" + msgContent + "]";
	}
	
	@Override
	public boolean equals(Object o) {
		
		if (this == o)
		{
			return true;
		}
		else if (o instanceof MessageInfo)
		{
			MessageInfo info = (MessageInfo) o;
			if (info.shortMsg != null && shortMsg != null && info.title != null && title != null)
			{
				if (info.msgId == msgId && info.shortMsg.equals(shortMsg) && info.title.equals(title)) { return true; }
			}
			else if (info.msgId == msgId) { return true; }
		}
		return false;
	}
	
	public String getTitle() {
		return title;
	}
	
	public void setTitle(String title) {
		this.title = title;
	}
	
	public String getShortMsg() {
		return shortMsg;
	}
	
	public void setShortMsg(String shortMsg) {
		this.shortMsg = shortMsg;
	}
	
	public String getLastMsgTime() {
		return lastMsgTime;
	}
	
	public void setLastMsgTime(String lastMsgTime) {
		this.lastMsgTime = lastMsgTime;
	}
	
	public List<BookInfo> getBooks() {
		return books;
	}
	
	public void setBooks(List<BookInfo> books) {
		this.books = books;
	}
	
	public String getPosition() {
		return position;
	}
	
	public void setPosition(String position) {
		this.position = position;
	}
	
	public String getCreateTime() {
		return createTime;
	}
	
	public void setCreateTime(String createTime) {
		this.createTime = createTime;
	}
	
	public long getBookId() {
		return bookId;
	}
	
	public void setBookId(long bookId) {
		this.bookId = bookId;
	}
	
	public String getEndTime() {
		return endTime;
	}
	
	public void setEndTime(String endTime) {
		this.endTime = endTime;
	}
	
	public int getSortNum() {
		return sortNum;
	}
	
	public void setSortNum(int sortNum) {
		this.sortNum = sortNum;
	}
	
	public String getStartTime() {
		return startTime;
	}
	
	public void setStartTime(String startTime) {
		this.startTime = startTime;
	}
	
	public String getAuthor() {
		return author;
	}
	
	public void setAuthor(String author) {
		this.author = author;
	}
	
	public int getLevel() {
		return level;
	}
	
	public void setLevel(int level) {
		this.level = level;
	}
	
	public String getEndTime2() {
		return endTime2;
	}
	
	public void setEndTime2(String endTime2) {
		this.endTime2 = endTime2;
	}
	
	public int getMsgId() {
		return msgId;
	}
	
	public void setMsgId(int msgId) {
		this.msgId = msgId;
	}
	
	public String getModifyTime() {
		return modifyTime;
	}
	
	public void setModifyTime(String modifyTime) {
		this.modifyTime = modifyTime;
	}
	
	public int getMsgViewId() {
		return msgViewId;
	}
	
	public void setMsgViewId(int msgViewId) {
		this.msgViewId = msgViewId;
	}
	
	public int getThirdEnterpriseId() {
		return thirdEnterpriseId;
	}
	
	public void setThirdEnterpriseId(int thirdEnterpriseId) {
		this.thirdEnterpriseId = thirdEnterpriseId;
	}
	
	public String getStatus() {
		return status;
	}
	
	public void setStatus(String status) {
		this.status = status;
	}
	
	public int getHanderId() {
		return handerId;
	}
	
	public void setHanderId(int handerId) {
		this.handerId = handerId;
	}
	
	public String getAddressUrl() {
		return addressUrl;
	}
	
	public void setAddressUrl(String addressUrl) {
		this.addressUrl = addressUrl;
	}
	
	public String getMsgImgUrl() {
		return msgImgUrl;
	}
	
	public void setMsgImgUrl(String msgImgUrl) {
		this.msgImgUrl = msgImgUrl;
	}
	
	public String getWriteSource() {
		return writeSource;
	}
	
	public void setWriteSource(String writeSource) {
		this.writeSource = writeSource;
	}
	
	public String getMsgContent() {
		return msgContent;
	}
	
	public void setMsgContent(String msgContent) {
		this.msgContent = msgContent;
	}
	
	public String getAccount() {
		return account;
	}
	
	public void setAccount(String account) {
		this.account = account;
	}
	
	public int getMsgType() {
		return msgType;
	}
	
	public void setMsgType(int msgType) {
		this.msgType = msgType;
	}
	
	public String getStartTime2() {
		return startTime2;
	}
	
	public void setStartTime2(String startTime2) {
		this.startTime2 = startTime2;
	}
	
	public String getIsRead() {
		return isRead;
	}
	
	public void setIsRead(String isRead) {
		this.isRead = isRead;
	}
	
	public SlideView getSlideView() {
		return slideView;
	}
	
	public void setSlideView(SlideView slideView) {
		this.slideView = slideView;
	}
	
}
